package com.wao.base.domain;

import org.hibernate.annotations.Filter;
import org.hibernate.annotations.FilterDef;
import org.hibernate.annotations.Filters;
import org.hibernate.annotations.ParamDef;

import javax.persistence.Column;
import javax.persistence.MappedSuperclass;

/**
 * Created by Arthur on 2017/4/11.
 */
@MappedSuperclass
@FilterDef(name = "waFilter", parameters = {@ParamDef(name = "wa_id", type = "long")})
@Filters({@Filter(name = "waFilter", condition = "wa_id = :wa_id")})
public abstract class BaseMultitenantEntity extends BaseEntity {
    private static final long serialVersionUID = 1L;

    @Column(name = "wa_id", nullable = false)
    protected Long waId;

    public Long getWaId() {
        return waId;
    }

    public void setWaId(Long waId) {
        this.waId = waId;
    }
}
